package com.briup.pai.convert;

import com.briup.pai.entity.po.Training;
import com.briup.pai.entity.vo.ModelHistoryVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;

@Mapper(componentModel = "spring")
public interface ModelHistoryBaseConvert {

    @Mapping(target = "modelVersion", source = "modelVersion")
    @Mapping(target = "accuracyRate", source = "accuracyRate")
    @Mapping(target = "trainDate", source = "createTime")
    @Mapping(target = "datasetNames", ignore = true)
    @Mapping(target = "trainResults", ignore = true)
    @Mapping(target = "evaluateReport", ignore = true)
    ModelHistoryVO toModelHistoryVO(Training training);
}

